package cn.xfdzx.android.apps.shop.contract;

import java.io.File;

import cn.xfdzx.android.apps.shop.base.BaseView;
import cn.xfdzx.android.apps.shop.bean.BaseObjectBean;
import cn.xfdzx.android.apps.shop.bean.LoginBean;
import cn.xfdzx.android.apps.shop.bean.UploadImgBeen;
import io.reactivex.Flowable;
import okhttp3.MultipartBody;
import retrofit2.http.Multipart;


/**
 * @author azheng
 * @date 2018/6/4.
 * Description：
 */

public interface UploadImageContract {
    interface Model {
        Flowable<UploadImgBeen> upload(MultipartBody.Part file);

    }

    interface View extends BaseView {
        @Override
        void showLoading();

        @Override
        void hideLoading();

        @Override
        void onError(Throwable throwable);

        void onUploadSuccess(UploadImgBeen bean);
    }

    interface Presenter {
        /**
         * 上传图片
         */
        void upload(File file);
    }
}
